/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package br.com.projetoObras.model.dao;

import br.com.projetoObras.model.Artist;
import java.sql.PreparedStatement;
import java.sql.SQLException;

/**
 *
 * @author viniciusvdias
 */
public class DAO {
    
    public static final void setValue(PreparedStatement pst, int id, Object value, int sqltype) throws SQLException{
        if(value == null || value.toString().isEmpty())
            pst.setNull(id, sqltype);
        else
            pst.setObject(id, value, sqltype);
                
    }
    
}
